<!-- 首页 -->
<template>
  <Topbar></Topbar>
  <div class="layout">
    <div class="home">
      <Searcher msg="山姆会员商店优惠商品"></Searcher>
      <div class="home-banner">
        <img :src="BANNER" alt="11.11狂欢节">
      </div>
      <Navbar></Navbar>
      <div class="gap"></div>
      <div class="main">
        <div class="main-title">附近店铺</div>
        <Nearby></Nearby>
      </div>
    </div>
  </div>
  <Docker page="home"></Docker>
</template>

<script>
import Docker from '@/components/docker'
import Searcher from '@/components/search'
import { BANNER } from '@/api/interface'
import Topbar from './components/topbar'
import Navbar from './components/navbar'
import Nearby from './components/nearby'
//composition
export default {
  name: 'home',
  components: { Docker, Topbar, Searcher, Navbar, Nearby },
  setup() {
    return { BANNER }
  }
}
</script>

<style scoped lang="scss">
@import '@/styles/mixin.scss';
@import '@/styles/theme.scss';

.layout {
  @include layout-remove-docker;
  padding-top: 14.4vw;

  .home {
    @include page-layout;
    padding: 0 4.8vw;

    &-banner {
      margin-top: 3.2vw;
      width: 100%;

      img {
        width: 100%;
        height: 22.9333vw;
      }
    }

    .gap {
      height: 2.6667vw;
      background: #F1F1F1;
      margin: 0 -4.8vw;
    }

    .main {
      padding: 16px 0;

      &-title {
        font-size: 18px;
        color: $theme-font-color;
        font-weight: bold;
      }
    }
  }
}</style>